﻿using System.Collections.Concurrent;

namespace System.Dns.Toolkit.DnsServer {

    public class NoPriorityQueue<TV> : IPriorityQueue<int, TV> {

        private readonly ConcurrentQueue<TV> _queues = new ConcurrentQueue<TV>();
        
        public void Enqueue(int priority, TV value) {
            _queues.Enqueue(value);
        }

        public bool TryDequeue(out TV value) {
            return _queues.TryDequeue(out value);
        }

        public bool IsEmpty {
            get {
                return _queues.IsEmpty;
            }
        }

        public int Count {
            get {
                return _queues.Count;
            }
        }

    }


}
